package com.niubility.server;


import com.niubility.entity.Article;
import com.niubility.vo.ArticleAll;

import java.util.List;

/**
 * @ClassName: ArticleDao
 * @Description: 实现文章各个部分的的显示,以及用户对自己文章的管理
 * @author: 张晨
 * @DATE: 2018/2/2
 */
public interface IArticleServer<A> {

//*****************************************************************
    //public boolean Save(int artid,int artMasterId,String artTitle,String artCover,String artContext,String artTexthead,int artGoodnum,int artcollectnum,int artAssessnum,int artReadnum,String artDate) ;

    public int SelectArticleNum();

    public boolean Save(Article article);
    public boolean Delete(int id, int userId);
    public boolean UpdateGoodnum(int id, int num);
    public boolean UpdateReadNum(int artId);
    public ArticleAll SelectById(int id);

//    public List<Article> SelectByMasterid(int id,int page,int num);
    public List<ArticleAll> SelectByRecommend(int page,int displayCounts,int artId,int userId,int masterId,int tag,int[] foledId);

    public boolean UpdateCollectNum(int artId, int num);     //张家乐调用方法

    public int SelectByTitle(Article article);          //徐松鹤根据文章题目和发布者ID查

    public boolean UpdateAssessnum(Article article);    //徐松鹤更改文章评论数量

    public int articleNum(int id);
}
